﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ObjectRelationalMap.Models
{
    public class Anecdote
    {
        internal int ID = -1;
        public string Note { get; set; }
        public string Domain { get; set; }
        public string Student { get; set; }
        public DateTime Date { get; set; }

        public Anecdote():this(null)
        {
        }

        public Anecdote(Anecdote anecdote)
        {
            if (anecdote != null)
            {
                Note = anecdote.Note;
                Domain = anecdote.Domain;
                Student = anecdote.Student;
                Date = anecdote.Date;
            }
            else
            {
                Note = "";
                Domain = "";
                Student = "";
                Date = DateTime.Now;
            }
        }

        public override string ToString()
        {
            return Note;
        }
    }
}
